The present invention relates to localization of faults in a controller area network and to the indication of the health of the controller area network.
Localization of faults in the physical layer of current industrial and other networks is a substantial problem. Such networks can extend over several hundred feet, can typically have more than 300 connection points, and can have 50 or more nodes. Faults in a network include, for example, bad or intermittent contacts, loose connections, broken wires, bad soldering, a failed transceiver or controller, a wet cable, EMI interference, and/or the like.
Because faults can occur at any location within a network, geographic localization of faults can be frequently difficult. Currently, even when it is possible to find a fault, finding its cause requires the investment of substantial time.
Moreover, as discussed above, some faults are intermittent, while other faults develop slowly over time. These types of network faults result in erratic network behavior, and they have no clear indications of cause. The diagnosis of such faults is, in general, very difficult.
The present invention is directed to an arrangement which addresses one or more of these problems.
In accordance with one aspect of the present invention, a method of determining health of a network comprises the following steps: a) determining a number of error messages transmitted over the network; b) determining a number of valid messages transmitted over the network; and, c) comparing the number of error messages to the number of valid messages in order to determine the health of the network.
In accordance with another aspect of the present invention, a node of a network comprises an error message detector arranged to detect error messages to transmitted over the network, a counter arranged to count the error messages in order to produce an error message count, and a controller arranged to produce a count of valid messages and to compare the error message count to the valid message count.
In accordance with yet another aspect of the present invention, a method of determining a location of a fault comprises the following steps: a) detecting a first error message from a receive line of a node; b) detecting a second error message from a transmit line of the node; c) if the first error message is detected before the second error message, determining that the node did not first transmit the second error message; and, d) if the second error message is detected before the first error message, determining that the node may have first transmitted the second error message.
In accordance with still another aspect of the present invention, a node comprises a transceiver coupled to a communication line, a controller coupled to the transceiver by a receive line and a transmit line, and error message first logic coupled to the receive and transmit lines. The error message first logic is arranged to detect a first error message from the receive line and a second error message from the transmit line, and the error message first logic is further arranged to determine whether the node is closest to a fault by comparing timing between the first error message and the second error message.